layui.use(["index", "cron",'admin'], function () {
    var $ = layui.$,
        cron = layui.cron,
        admin = layui.admin;
    var cronStr = admin.getTempData('cron');

    $("#cronVal").val(cronStr);
    cron.render({
        elem: "#cronVal", // 绑定元素
        url:Feng.ctxPath + "/sysJob/cron", // 获取最近运行时间的接口
        value: $("#cronVal").val(), // 默认值
        done: function (cronStr) {
            admin.putTempData('cron', cronStr);
            var cronIndex = admin.getTempData('cronIndex');
            top.layer.close(cronIndex);
        },
        close: function () {

            admin.putTempData('cron', admin.getTempData('cron'));
            var cronIndex = admin.getTempData('cronIndex');
            top.layer.close(cronIndex);
        }
    });
});